/**
 * Created by mac on 2017/7/12.
 */
import React, { Component } from 'react';
import {
    AppRegistry,
    StyleSheet,
    Text,
    View,
    Image,
    Dimensions,
    ScrollView,
    StatusBar,
    ListView,
    DeviceEventEmitter,
    TouchableOpacity

} from 'react-native';

export default class FloatView extends Component{

    render(){
        return (
            <View style={this.props.style}>
                <View style={{width:40,height:40,justifyContent:'center',borderRadius:20}}>
                    <TouchableOpacity onPress={()=>this.props.click()}>
                        <Image source={require('./images/icon-stick@2x.png')} style={{width:40,height:40}}/>
                    </TouchableOpacity>
                    <View style={{justifyContent:'center',position:'absolute',width:40,height:40,borderRadius:20,display:this.props.display,backgroundColor:'#474747'}}>
                        <Text style={{alignSelf:'center',textAlign:'center',color:'white'}}>{this.props.currentPage}</Text>
                        <View style={{width:40,height:1,backgroundColor:'white'}} />
                        <Text style={{alignSelf:'center',textAlign:'center',color:'white'}}>{this.props.count}</Text>
                    </View>
                </View>
                <View style={{width:40,height:40,justifyContent:'center',borderRadius:20,backgroundColor:'#7fc038',marginTop:5}}>
                    <Image source={require('./images/icon-search@2x.png')} style={{width:36*0.5,height:36*0.5,alignSelf:'center',marginTop:5}}/>
                </View>
                <View style={{width:40,height:40,justifyContent:'center',borderRadius:20,backgroundColor:'#7fc038',marginTop:5}}>
                    <Image source={require('./images/icon-chat@2x.png')} style={{width:34*0.5,height:29*0.5,alignSelf:'center'}}/>
                </View>
            </View>
        )
    }
}